package com.homedo.odin.solution.service;

import com.homedo.core.common.base.service.BaseService;
import com.homedo.odin.solution.dao.UserLoginMapper;
import com.homedo.odin.solution.model.entity.UserLogin;
import org.springframework.stereotype.Service;

/**
 * <p> 用户第三方登录绑定表 服务实现类 </p>
 *
 * @author HarveyDing
 * @since 2018-03-08
 */
@Service
public class UserLoginServiceImpl extends BaseService<UserLoginMapper, UserLogin> {


    public void addUserLogin(UserLogin userLogin) {
        baseMapper.insert(userLogin);
    }

    public UserLogin getUserLogin(String openId) {
        return baseMapper.getUserLogin(openId);
    }

    public void updateUserLogin(UserLogin userLogin) {
        baseMapper.updateById(userLogin);
    }

}
